package com.sumer.psychology.common.domain.model;

/**
 * 性别
 * <p/>
 * Created by twer on 15/3/29.
 */
public enum Gender {
    MAN(1) {
        @Override
        public String toString() {
            return "男";
        }
    },

    WOMAN(2) {
        @Override
        public String toString() {
            return "女";
        }
    };

    private final int value;

    Gender(int value) {
        this.value = value;
    }

    public static Gender create(int value) {
        if (value == 1) {
            return MAN;
        } else {
            return WOMAN;
        }
    }

    public int value() {
        return value;
    }
}
